<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <style>
			
			 .box{
			 	 width:300px;
			 	 height:200px;
			 	 border:1px solid red;
			 	 overflow:hidden;
			 }

			 .one,.two,.tree{
			 	 width:300px;
			 	 height:200px;
			 }

			 .one{
			 	  
			 	  background-color:green;
			 }
			 .two{
			 	 
			 	  background-color:pink;

			 }
			 .tree{
			 	 
			 	  background-color:yellowgreen;
			 }
			 a{
			 	display:inline-block;
			 	width:40px;
			 	border:1px solid green;
			 }
        </style>
    </head>
    <body>
    	  <a href="#one">div1</a>
    	  <a href="#two">div2</a>
    	  <a href="#tree">div3</a>
		 <div class="box">
		 	
		 	 <div class="one" id="one">
		 	 	div1
		 	 </div>
		 	 <div class="two" id="two">
		 	 	div2
		 	 </div>
		 	 <div class="tree" id="tree">
		 	 	div3
		 	 </div>
		 </div>
        
    </body>
</html>